<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <?php $event_id = $_REQUEST['event'] ?>
    <?php include "../controller/index.php" ;?>
    <?php include 'modules/head.php'; ?>

</head>

<body id="top">

<?php include 'modules/header.php'; ?>

<div class="mui-content index_content">


    <div class="item-list">
        <h4>请如实填写报名资料</h4>
        <form action="index.php?action=applying&event=<?echo $_REQUEST['event']?>" method="post" enctype="multipart/form-data">

            <?if($_apply_info){?>
                <div  style="background-color: #fffbd3;
    padding: 10px;
    margin-bottom: 10px;">资料已提交，请返回继续报名</div>
                <?;}?>


            <ul class="mui-table-view ">
                <li class="mui-input-row">
                    <label>姓名</label>
                    <input type="text" name="ai_name" id="name"
                           class="mui-input-clear"
                           placeholder="姓名" required
                           value="<?echo $_apply_info['name'] ?>"

                        <? if($_apply_info){echo "disabled";} ?>
                    >
                </li>

                <!---->
                <!--            <li class="mui-input-row " >-->
                <!--                <label>性别</label>-->
                <!---->
                <!---->
                <!--                <div class="radio-box">-->
                <!--                <div class="  mui-radio mui-left" >-->
                <!--                    <label>男</label>-->
                <!--                    <input name="radio1" type="radio">-->
                <!--                </div>-->
                <!--                <div class="  mui-radio mui-left" >-->
                <!--                    <label>女</label>-->
                <!--                    <input name="radio1" type="radio">-->
                <!--                </div>-->
                <!--                </div>-->
                <!--            </li>-->


                <?if(in_array("年龄",$_apply_item)){?>
                    <li class="mui-input-row">
                        <label>年龄</label>
                        <input type="text" name="ai_age" class="mui-input-clear" placeholder="年龄" required value="<?echo $_apply_info['age'] ?>"  <? if($_apply_info){echo "disabled";} ?>>
                    </li>
                <?}?>

                <?if(in_array("身份证号",$_apply_item)){?>
                    <li class="mui-input-row">
                        <label>身份证号</label>
                        <input type="text" name="ai_idnumber" class="mui-input-clear" placeholder="身份证号" required value="<?echo $_apply_info['idnumber'] ?>"   <? if($_apply_info){echo "disabled";} ?> >
                    </li>
                <?}?>

                <?if(in_array("所属单位",$_apply_item)){?>
                    <li class="mui-input-row">
                        <label>所属单位</label>
                        <input type="text" name="ai_unit" class="mui-input-clear" placeholder="所属单位" required value="<?echo $_apply_info['unit'] ?>"   <? if($_apply_info){echo "disabled";} ?> >
                    </li>
                <?}?>

                <?if(in_array("所属团体",$_apply_item)){?>
                    <li class="mui-input-row">
                        <label>所属团体</label>
                        <input type="text" name="ai_groups" class="mui-input-clear" placeholder="请输入所属团体名称" required value="<?echo $_apply_info['groups'] ?>"   <? if($_apply_info){echo "disabled";} ?> >
                    </li>
                <?}?>

                <?if(in_array("队伍名称",$_apply_item)){?>
                    <li class="mui-input-row">
                        <label>队伍名称</label>
                        <input type="text" name="ai_team" class="mui-input-clear" placeholder="请输入队伍名称" required  value="<?echo $_apply_info['team'] ?>"   <? if($_apply_info){echo "disabled";} ?>
                    </li>
                <?}?>

                <?if(in_array("备注",$_apply_item)){?>
                    <li class="mui-input-row">
                        <label>备注</label>
                        <input type="text" name="ai_remark" class="mui-input-clear" placeholder="请输入备注"   value="<?echo $_apply_info['remark'] ?>"   <? if($_apply_info){echo "disabled";} ?> >
                    </li>
                <?}?>

            </ul>

            <input type="hidden" name="ai_event_nid" id="event" value="<?echo $_REQUEST['event']?>">
            <input type="hidden" name="ai_member_nid"  id="member"  value="<?echo $_REQUEST['member']?>">


            <br class="clearfloat"/>

            <? if($_apply_info){?>
                <div class="function"><button style="font-size: 24px;
    height: 50px;margin-bottom:30px" type="button" class="mui-btn mui-btn-primary"> 资料已提交 </button> </div>

                <?;}else{?>
                <div class="function"><button id="applybutton" style="font-size: 20px;
    height: 50px;margin-bottom:30px"  class="mui-btn mui-btn-primary button"> 提交 </button> </div>
            <?}?>

        </form>

    </div>

</div>



<script src="/application/mui/js/mui.min.js"></script>
<script src="/application/js-sdk/jweixin-1.3.2.js"></script>
<?if($_apply_info){?>
    <script>
        let url = '/pages/activity/pay?id=' + '<?echo $event_id ?>';
        wx.miniProgram.reLaunch({url: url});
    </script>
    <?;}?>
</body>
</html>



















